package com.woniuxy.store.client;

import com.woniuxy.store.client.param.reservationParam.InsertReservationParams;
import com.woniuxy.store.client.param.reservationParam.SearchReservationByConditionParams;
import com.woniuxy.store.client.param.reservationParam.UpdateReservationStateParams;
import common.WoniuPage;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.*;
import result.Result;

@FeignClient(contextId = "ReservationClient",name = "store",path = "/store/reservation")
public interface ReservationClient {
    @PostMapping({"/insertReservation"})
    Result insertReservation(@RequestBody InsertReservationParams param);

    @PutMapping({"/updateReservationState"})
    Result updateReservationState(@RequestBody UpdateReservationStateParams param);

    @DeleteMapping({"/deleteReservation"})
    Result deleteReservation(@RequestParam("reservationId") Integer reservationId);

    @GetMapping({"/searchReservationByCondition"})
    Result searchReservationByCondition(@SpringQueryMap SearchReservationByConditionParams var1);
}
